package sdk;

import java.util.ArrayList;
import java.util.Arrays;

public class VectorSDK
{
	private  String[] vectorSDK = new String[9];
	private int xPos;
	private int yPos;

	public VectorSDK(String[] vectorSDK)
	{
		this.vectorSDK = vectorSDK;
	}
	
	public VectorSDK()
	{
		for(int i=0;i<9;i++){
			vectorSDK[i]="*";
		}
	}

	public String[] getVectorSDK()
	{
		return vectorSDK;
	}

	public void setElement(String[] vectorSDK)
	{
		this.vectorSDK = vectorSDK;
	}

	public int getxPos()
	{
		return xPos;
	}

	public void setxPos(int xPos)
	{
		this.xPos = xPos;
	}

	public int getyPos()
	{
		return yPos;
	}

	public void setyPos(int yPos)
	{
		this.yPos = yPos;
	}

	@Override
	public String toString()
	{
		String res = "";
		for(int i=0;i<9;i++){
			res=res+vectorSDK[i]+".";
		}
		return"["+res+"] ["+xPos+"."+yPos+"]";
	}
	
	public String getLine(){
		String res="";
		ArrayList<String> arraySDK = new ArrayList<String>(Arrays.asList(vectorSDK));
		for(int i=0;i<9;i++){
			if (!arraySDK.contains((i+1)+"")){
				res=res+(i+1);
			}else{
				res=res+".";
			}

		}
		return res;
	}
	
	
}
